package com.cda.pes.VO;

import java.util.Objects;

/**
 * @author cdastart
 * @create 2021-10-27 15:27
 */
public class FavouriteVO {
    private Integer fid;
    private Integer uid;
    private Integer pid;
    private String  title;
    private Long price;
    private String image;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        FavouriteVO that = (FavouriteVO) o;
        return Objects.equals(fid, that.fid) &&
                Objects.equals(uid, that.uid) &&
                Objects.equals(pid, that.pid) &&
                Objects.equals(title, that.title) &&
                Objects.equals(price, that.price) &&
                Objects.equals(image, that.image);
    }

    @Override
    public int hashCode() {
        return Objects.hash(fid, uid, pid, title, price, image);
    }

    @Override
    public String toString() {
        return "FavouriteVO{" +
                "fid=" + fid +
                ", uid=" + uid +
                ", pid=" + pid +
                ", title='" + title + '\'' +
                ", price=" + price +
                ", image='" + image + '\'' +
                '}';
    }

    public FavouriteVO(Integer fid, Integer uid, Integer pid, String title, Long price, String image) {
        this.fid = fid;
        this.uid = uid;
        this.pid = pid;
        this.title = title;
        this.price = price;
        this.image = image;
    }

    public FavouriteVO() {
    }

    public Integer getFid() {
        return fid;
    }

    public void setFid(Integer fid) {
        this.fid = fid;
    }

    public Integer getUid() {
        return uid;
    }

    public void setUid(Integer uid) {
        this.uid = uid;
    }

    public Integer getPid() {
        return pid;
    }

    public void setPid(Integer pid) {
        this.pid = pid;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public Long getPrice() {
        return price;
    }

    public void setPrice(Long price) {
        this.price = price;
    }

    public String getImage() {
        return image;
    }

    public void setImage(String image) {
        this.image = image;
    }
}
